﻿#include "DataPackage_TcpCodec.h"

DataPackage_TcpCodec::DataPackage_TcpCodec() : QObject()
{

}

DataPackage_TcpCodec::DataPackage_TcpCodec(const DataPackage_TcpCodec& dataPackageInfo_User)
{
  setUserId(dataPackageInfo_User.getUserId());
  setPackageType(dataPackageInfo_User.getPackageType());
  setData(dataPackageInfo_User.getData());
}

DataPackage_TcpCodec::~DataPackage_TcpCodec()
{

}

uint DataPackage_TcpCodec::getUserId() const
{
  return userId;
}

DataPackage_TcpCodec* DataPackage_TcpCodec::setUserId(const uint userId)
{
  this->userId=userId;
  return this;
}

unsigned char DataPackage_TcpCodec::getPackageType()const
{
  return packageType;
}

DataPackage_TcpCodec* DataPackage_TcpCodec::setPackageType(unsigned char packageType)
{
  this->packageType=packageType;
  return this;
}

QByteArray DataPackage_TcpCodec::getData() const
{
  return data;
}

DataPackage_TcpCodec* DataPackage_TcpCodec::setData(const QByteArray data)
{
  this->data=data;
  return this;
}
